import http from '@/utils/http';

const role = {
  //
  getRoles() {
    let url = '/admin/Role/GetRoles';
    return http.get(url);
  },
  //角色视图
  query(params: any) {
    let url = '/admin/Role/Query';
    return http.post(url, params);
  },
  //角色详情
  detail(id: Number) {
    let url = '/admin/Role/Detail';
    let params = { id: id };
    return http.get(url, params);
  },
  //角色保存
  save(role: Object) {
    let url = '/admin/Role/Save';
    return http.post(url, role);
  },
};
export default role;
